module.exports = {
	publicPath: process.env.NODE_ENV === 'production' ? './' : '/',
	css: {
		loaderOptions: {
			sass: {
				prependData: `@import "@/styles/variables.scss";`
			}
		}
	},
	// 默认打开eslint效验，如果需要关闭，设置成false即可
	lintOnSave: false,
	productionSourceMap: false,
	devServer: {
		proxy: {
			'/api': {
				// target: 'http://192.168.1.115:8080', //广坤
				// target: 'http://192.168.1.106:8080', //庆文
				target: 'https://jst.jiningdq.cn/',
				changeOrigin: true,
				pathRewrite: {
					'/api': ''
				}
			},
			'/system': {
				target: process.env.VUE_APP_BASE_API,
				changeOrigin: true,
				pathRewrite: {
					'/system': 'system'
				},
			}
		},
		// 此处开启 https
		// https: true,
		open: true,
		port: 8080,
		overlay: {
			errors: true,
			warnings: true
		}
	}
}
